Security News
vlt Debuts New JavaScript Package Manager and Serverless Registry at NodeConf EU
vlt introduced its new package manager and a serverless registry this week, innovating in a space where npm has stagnated.
@nextgis/properties-filter
Advanced tools
An auxiliary library that allows filtering objects by its properties using JSON-serializable expressions
# latest stable
$ npm install --save-dev @nextgis/properties-filter
# or
$ yarn add @nextgis/properties-filter
General view of expression
[ С , [E1] , [E2] , [EN] ]
С - condition (optional). May be 'all' or 'any';
E - expression:
[key, operator, value]
gt
, lt
, ge
, le
, eq
, ne
, in
, notin
, like
, ilike
;in
and notin
:
like
and ilike
:
Place %
-character after or before key
string to determine the direction of search.
Nesting
[ [E1], ['any', [E2], [E3, E4] ], ['any', [E5], [E6] ] ] ]
Example
import { propertiesFilter, featureFilter } from '@nextgis/properties-filter';
const properties = {
place: 'Tofalaria',
area: 21,
};
propertiesFilter(properties, [['place', 'eq', 'Tofalaria']]); // true
propertiesFilter(properties, [['place', 'in', ['Tofalaria', 'Siberia']]]); // true
propertiesFilter(properties, [['place%', 'like', 'Tof']]); // true
propertiesFilter(properties, [
// 'and', // - by default
['place', 'eq', 'Tofalaria'],
['area', 'ge', 21],
]); // true
propertiesFilter(properties, [
'any',
['place', 'eq', 'Siberia'],
['area', 'gt', 10],
]); // true
Need to fix a bug or add a feature to @nextgis/properties-filter
? We provide custom development and support for this software. Contact us to discuss options!
FAQs
Filtering objects by its properties using expressions
The npm package @nextgis/properties-filter receives a total of 43 weekly downloads. As such, @nextgis/properties-filter popularity was classified as not popular.
We found that @nextgis/properties-filter demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
vlt introduced its new package manager and a serverless registry this week, innovating in a space where npm has stagnated.
Security News
Research
The Socket Research Team uncovered a malicious Python package typosquatting the popular 'fabric' SSH library, silently exfiltrating AWS credentials from unsuspecting developers.
Security News
At its inaugural meeting, the JSR Working Group outlined plans for an open governance model and a roadmap to enhance JavaScript package management.